package ua.epam.java_bravo.data.dao;

import ua.epam.java_bravo.data.dto.HsWorkscale;
import ua.epam.java_bravo.data.dto.pk.HsWorkscalePk;
import ua.epam.java_bravo.data.exception.HsWorkscaleDaoException;

public interface HsWorkscaleDao {
    /**
     * Inserts a new row in the HS_WorkScale table.
     */
    public HsWorkscalePk insert(HsWorkscale dto) throws HsWorkscaleDaoException;

    /**
     * Updates a single row in the HS_WorkScale table.
     */
    public void update(HsWorkscalePk pk, HsWorkscale dto) throws HsWorkscaleDaoException;

    /**
     * Deletes a single row in the HS_WorkScale table.
     */
    public void delete(HsWorkscalePk pk) throws HsWorkscaleDaoException;

    /**
     * Returns the rows from the HS_WorkScale table that matches the specified primary-key value.
     */
    public HsWorkscale findByPrimaryKey(HsWorkscalePk pk) throws HsWorkscaleDaoException;

    /**
     * Returns all rows from the HS_WorkScale table that match the criteria 'workScale_id = :workscaleId'.
     */
    public HsWorkscale findByPrimaryKey(int workscaleId) throws HsWorkscaleDaoException;

    /**
     * Returns all rows from the HS_WorkScale table that match the criteria ''.
     */
    public HsWorkscale[] findAll() throws HsWorkscaleDaoException;

    /**
     * Returns all rows from the HS_WorkScale table that match the criteria 'workScale_id = :workscaleId'.
     */
    public HsWorkscale[] findWhereWorkscaleIdEquals(int workscaleId) throws HsWorkscaleDaoException;

    /**
     * Returns all rows from the HS_WorkScale table that match the criteria 'name = :name'.
     */
    public HsWorkscale[] findWhereNameEquals(String name) throws HsWorkscaleDaoException;

    /**
     * Sets the value of maxRows
     */
    public void setMaxRows(int maxRows);

    /**
     * Gets the value of maxRows
     */
    public int getMaxRows();

    /**
     * Returns all rows from the HS_WorkScale table that match the specified arbitrary SQL statement
     */
    public HsWorkscale[] findByDynamicSelect(String sql, Object[] sqlParams) throws HsWorkscaleDaoException;

    /**
     * Returns all rows from the HS_WorkScale table that match the specified arbitrary SQL statement
     */
    public HsWorkscale[] findByDynamicWhere(String sql, Object[] sqlParams) throws HsWorkscaleDaoException;

}
